#pragma once

#include "resource_handle.hpp"

namespace winboost {
   namespace resources {

struct deleter_accel
{
   void operator()(HACCEL h)   {::DestroyAcceleratorTable(h);}
};

class accelerator : public resource_handle<HACCEL__>
{
   virtual void set_id_impl(LPCTSTR ids, HINSTANCE hinst)
   {
      m_handle = handle_type(::LoadAccelerators(hinst, ids), deleter_accel());
   }
};

   }
}
